package net.lahuobao.mall.service.admin;

import net.lahuobao.mall.entity.admin.MallSubsidyDetailEntity;
import net.lahuobao.mall.entity.admin.MallSubsidyEntity;
import net.lahuobao.mall.entity.admin.resultmodel.MallSubsidyResultEntity;
import org.jeecgframework.core.common.service.CommonService;

import java.util.List;

public interface MallSubsidyServiceI extends CommonService{

    /**
     * 保存折扣信息
     * @param subsidyEntity
     * @param mallSubsidyDetailEntityList
     */
    public void save(MallSubsidyEntity subsidyEntity, List<MallSubsidyDetailEntity> mallSubsidyDetailEntityList);

    /**
     * 更新折扣信息
     * @param subsidyEntity
     * @param mallSubsidyDetailEntityList
     */
    public void update(MallSubsidyEntity subsidyEntity, List<MallSubsidyDetailEntity> mallSubsidyDetailEntityList);


    /**
     * 根据商品id获取商品的折扣信息
     * @param productId
     * @return
     */
    public MallSubsidyResultEntity selectSubsidyByProductId(Integer productId);
}
